package com.jason.sms.agent.protocol.cmpp3.client;

import java.util.Properties;

public class Configer {
	
	private static final String ConfigPath = "/cmpp.properties";

	private static final String SpId = "SP.id";
	
	private static final String SpPwd = "SP.pwd";
	
	private static final String ISMG_IP = "ISMG.ip";
	
	private static final String ISMG_PORT = "ISMG.port";
	
	
	static Properties property;
	
	static{
		property = new Properties();
		try{
			property.load(Configer.class.getResourceAsStream(ConfigPath));
		}catch(Exception e){
			e.printStackTrace();
		}
	}
	
	public static String getSpId(){
		return property.getProperty(SpId);
	}
	
	public static String getSpPwd(){
		return property.getProperty(SpPwd);
	}
	
	public static String getIsmgIp(){
		return property.getProperty(ISMG_IP);
	}
	
	public static int getIsmgPort(){
		int port = Integer.parseInt(property.getProperty(ISMG_PORT));
		return port;
	}
}
